allocate ComboCellInfo with GSlice.
authorMichael Natterer <mitch@imendio.com>
Fri, 4 Jul 2008 10:52:52 +0000 (10:52 +0000)
committerMichael Natterer <mitch@src.gnome.org>
Fri, 4 Jul 2008 10:52:52 +0000 (10:52 +0000)
2008-07-04  Michael Natterer  <mitch@imendio.com>

* gtk/gtkcombobox.c: allocate ComboCellInfo with GSlice.

svn path=/trunk/; revision=20760

ChangeLog
gtk/gtkcombobox.c

index 48e0e76767f78adc6975e26083be41c5f57a3397..855d7ebd60842ede63dbef94c2d40334b33aafee 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2008-07-04  Michael Natterer  <mitch@imendio.com>
+
+       * gtk/gtkcombobox.c: allocate ComboCellInfo with GSlice.
+
 2008-07-04  Michael Natterer  <mitch@imendio.com>
 
        * gtk/gtkprintoperation.c (print_pages): change "error_dialog"
index 3364366b00aa913fb5a1bd3b6235b3703d0f254b..cf2ddff020fda7cf38a469b4aad6dde53fe47413 100644 (file)
@@ -4089,7 +4089,7 @@ gtk_combo_box_cell_layout_pack_start (GtkCellLayout   *layout,
 
   g_object_ref_sink (cell);
 
-  info = g_new0 (ComboCellInfo, 1);
+  info = g_slice_new0 (ComboCellInfo);
   info->cell = cell;
   info->expand = expand;
   info->pack = GTK_PACK_START;
@@ -4143,7 +4143,7 @@ gtk_combo_box_cell_layout_pack_end (GtkCellLayout   *layout,
 
   g_object_ref_sink (cell);
 
-  info = g_new0 (ComboCellInfo, 1);
+  info = g_slice_new0 (ComboCellInfo);
   info->cell = cell;
   info->expand = expand;
   info->pack = GTK_PACK_END;
@@ -4213,11 +4213,11 @@ gtk_combo_box_cell_layout_clear (GtkCellLayout *layout)
 
   for (i = priv->cells; i; i = i->next)
     {
-     ComboCellInfo *info = (ComboCellInfo *)i->data;
+      ComboCellInfo *info = (ComboCellInfo *)i->data;
 
       gtk_combo_box_cell_layout_clear_attributes (layout, info->cell);
       g_object_unref (info->cell);
-      g_free (info);
+      g_slice_free (ComboCellInfo, info);
       i->data = NULL;
     }
   g_slist_free (priv->cells);
@@ -5343,7 +5343,7 @@ gtk_combo_box_finalize (GObject *object)
       g_slist_free (info->attributes);
 
       g_object_unref (info->cell);
-      g_free (info);
+      g_slice_free (ComboCellInfo, info);
     }
    g_slist_free (combo_box->priv->cells);